package com.bop.dehong.http.model;

import java.lang.reflect.Type;

import android.app.Activity;

import com.base.dehong.http.HttpRequest;
import com.base.dehong.http.RequestCallBack;
import com.bop.dehong.config.Config;
import com.bop.dehong.info.ForgotPasswordInfo;
import com.google.gson.reflect.TypeToken;
/**
 * 忘记密码
 * @author Tangwenhan
 *
 */
public class ForgotPasswordModel extends HttpRequest<ForgotPasswordInfo>{

	public ForgotPasswordModel(Activity activity,
			RequestCallBack<ForgotPasswordInfo> callback) {
		super(activity, callback);
		// TODO Auto-generated constructor stub
	}
	public void doNet(String phone,String phonecode) {
		mPostValues.put("a", "rpassword");
		mPostValues.put("cellphone", phone);
		mPostValues.put("m", "Passport");
		mPostValues.put("phonecode", phonecode);		
		requestByPost();
	}

	@Override
	public String getURL() {
		return Config.getIP() + Config.getForgotUrl();
	}

	@Override
	public Type getType() {
		return new TypeToken<ForgotPasswordInfo>() {}.getType();
	}
	
	@Override
	public Class<ForgotPasswordInfo> getClazz()
	{
		return ForgotPasswordInfo.class;
	}

}
